<header>
  <nav>
    <div class="menu_div">
      <a href="/" class="webName">天网</a>
      <a href="/" class="article_nav">文章</a>
      <a class="chat_room_nav">聊天室</a>
      <a  class="message_board_nav">留言板</a>
    </div>

    <div class="login_div">
      <%if(user && Object.keys(user).length !== 0){%>
        <a href="javascript:;" class="login_nav"><%=user.name%></a>
        <a href="/login/exit" class="register_nav">退出</a>
      <%}else{%>
        <a href="/login/login" class="login_nav">登录</a>
        <a href="/login/register" class="register_nav">注册</a>
      <%}%>

    </div>
  </nav>
</header>
